<script lang="ts" setup>
import { TgshListQueryResult } from '@/api/gdgl-dto'
import { ref } from 'vue'
/*
 * 打开弹框
 */
//
const dialogVisible = ref<boolean>(false)
// 入参
// 生命周期
const openDialog = (val: TgshListQueryResult) => {
  tableData.value = [val]
  dialogVisible.value = true
}
const tableData = ref<TgshListQueryResult[]>([])

defineExpose({ openDialog })
</script>
<template>
  <el-dialog v-model="dialogVisible" title="案卷详情" width="80%" :close-on-click-modal="false">
    <div class="dialog-box">
      <el-table :data="tableData" height="400">
        <el-table-column prop="dh" label="档号" width="160" />
        <el-table-column prop="ajlx" label="案卷类别" width="150" />
        <el-table-column prop="ajsl" label="案卷数量" />
        <el-table-column prop="zys" label="总页数" />
        <el-table-column prop="zzys" label="纸质页数" />
        <el-table-column prop="yspsl" label="音像" />
        <el-table-column prop="gdrq" label="归档日期" width="100" />
      </el-table>
    </div>
    <template #footer>
      <div class="dialog-footer">
        <el-button @click="dialogVisible = false">关 闭</el-button>
      </div>
    </template>
  </el-dialog>
</template>
<style lang="scss" scoped>
.dialog-box {
  width: 100%;
}
</style>
